<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <meta http-equiv="content-type" content="text/html; charset=utf-8" />
  <title><%=@page_title%></title>
  <%= stylesheet_link_tag "paths", :media => "all" %>
  <%= javascript_include_tag :defaults %>
</head>
<body>
  <div id="header">
    <div id="logo"><a href="/" title="Go to Make A Path home page"><img src="/images/logo.gif" border="0" /></a></div>
    <div id="top">
      <div id="account">
        <%if current_user %>
      	  Welcome:
          <%= link_to(current_user.login, user_path(current_user), {:title => "{current_user.login}'s very own personal home page."}) %>
          <span id="signout">(<a href="/signout" title="Sign out of your Make A Path account">Sign Out</a>)</span>
        <%else%>
          <a href="/signup" title="Sign up for an account on Make A Path">Sign Up</a> or
          <a href="/signin" title="Sign in to your Make A Path account">Sign In</a>
        <%end%>
      </div>    
      <div id="search">
        <% form_tag(:controller => 'search', :action => 'search_results') do %>
          <%= text_field('search', 'terms', :size => 30, :class => 'input-box', :value => params[:search] ? params[:search][:terms] : 'search', :onClick => "this.value=''") %>
          <%= submit_tag(" Search! ", :class => "input-button") %>
        <% end %>
      </div>
    </div>
    <div id="topbar">
      <div class="main-link" style="margin-left:14px"><%= link_to 'Home', {:controller => 'default', :action => 'index'}, {:title => 'make a path Home'} %></div>
      <div class="main-link"><%= link_to 'Users', users_path %></div>
      <div class="main-link"><%= link_to 'Newest Paths', paths_path %></div>
      <% if current_user %><div class="main-link"><%= link_to('My Paths', {:controller => 'users', :action => 'paths', :id => current_user.id }, {:title => "View your paths."}) %></div><% end %>
      <div id="help">
        <div class="main-link"><%=link_to 'Advanced Search', {:controller => 'search', :action => 'index'}, {:title => 'Advanced Search - look for paths in an advanced way.'}%></div>
        <div class="main-link"><%=link_to 'Help', {:controller => 'users', :action => 'welcome'}, {:title => 'Get some help.'}%></div>
      </div>      
    </div>
  </div>
  <div id="content">
    <div id="messages">
      <% for name in [:notice, :warning, :message] %>
        <% if flash[name] %>
          <%= "<div class=\"message\" id=\"#{name}\">#{flash[name]}</div>" %>
        <% end %>
      <% end %>
    </div>
    <div id="main-content">
      <%= @content_for_layout %>
    </div>
  </div>
  <div id="footer">
    <%=link_to 'get the make a path bookmarklet', {:controller => 'default', :action => 'bookmarklet'}, {:title => 'get the make a path bookmarklet'} %> 
    <a href="http://cosl.usu.edu/projects/mocsl/makeapath" title="More information about make a path">about</a> bookmark this in 
    <a href="http://del.icio.us/post?v=2&url=http://makeapath.com/&title=makeapath!" alt="Bookmark in del.icio.us">delicious</a> or
    <a href="http://digg.com/submit?phase=2&url=http://makeapath.com/">digg it!</a> or
    <a href="javascript:e=encodeURIComponent;w=window;gs=w.getSelection;d=document;dgs=d.getSelection;l=location;s='http://www.ozmozr.com/submit?u=';w.onerror=function(){l.href=s+e(l.href)+'&t='+e(d.title);};c=gs?gs():dgs?dgs():d.selection?d.selection.createRange().text:'';if(c==''){de=d.getElementsByName('Description');c=de&&de[0]?c=de[0].content:''}l.href=s+e(l.href)+'&t='+e(d.title)+'&c='+e(c);">ozmoze it!</a>
  </div>
</body>
</html>